<?php
class Home extends Controller {
	function Home(){
		parent::Controller();
		$this->load->helper(array('url','function','common'));
 		$this->load->scaffolding('mc_news');
 		//调用前台公用Model
 		$this->load->model('Mhome');
	}
	
	//Index页面
	function index(){
		load_view("index",$this->data());		
	}
	//最新公告
	function news(){
		load_view("news",$this->data());		
	}

	//网吧列表
	function netbar(){
		load_view("area",$this->data());		
	}



	function data(){
		/*--------------------------------左侧部分【left】---------------------------------*/
		$data['lastes_news']=$this->Mhome->lastes_news($num=8);
		$data['banks']=$this->Mhome->banks();
		/*--------------------------------网站首页【index】-------------------------------*/
		//网吧加盟index.php
		$data['netbar']=$this->Mhome->netbar();
		//角色代练index.php
		$data['products_type']=$this->Mhome->products_type(10);//滑动门i的起始值
		//热门套餐index.php
		$data['hot_products']=$this->Mhome->hot_products(12);
		$data['news']=$this->Mhome->news($this->uri->segment(3,0),1);
		$data['flag']=NULL;
		return $data;
	}

}//end C_home
/* End of file home.php */
/* Location: ./system/application/controllers/home.php */